package com.zy.sso.client.dto;

import java.io.Serializable;
import java.time.LocalDateTime;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.zy.sso.client.utils.RandomUtil;


public class BaseUser implements Serializable{
	
    /**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	private String gid = RandomUtil.get32UUID();

	public String account;

	private String password;
	
	private String fromSystem;//注册系统
    
	private UserStatus status;
    
	@JsonFormat(locale="zh", timezone="GMT+8", pattern="yyyy-MM-dd HH:mm:ss")
	private LocalDateTime createTime = LocalDateTime.now();

    public enum UserStatus{
    	init,normal,frozen,cancellation;//初始化，正常，冻结，注销
    }

	public String getGid() {
		return gid;
	}

	public void setGid(String gid) {
		this.gid = gid;
	}

	public String getAccount() {
		return account;
	}

	public void setAccount(String account) {
		this.account = account;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getFromSystem() {
		return fromSystem;
	}

	public void setFromSystem(String fromSystem) {
		this.fromSystem = fromSystem;
	}

	public UserStatus getStatus() {
		return status;
	}

	public void setStatus(UserStatus status) {
		this.status = status;
	}

	public LocalDateTime getCreateTime() {
		return createTime;
	}

	public void setCreateTime(LocalDateTime createTime) {
		this.createTime = createTime;
	}

}
